import request from '@/utils/request'
/**
 * 分页取件人列表
 * @param pageNum
 * @param pageSize
 */
const getList = function(pageNum,pageSize) {
  return request({
    url: '/pick/list',
    method: 'post',
    data: {
      pageNum:pageNum,
      pageSize:pageSize
    }
  })
}

/**
 * 删除
 * @param id
 */
const deleted = function(ids) {
  return request({
    url: '/pick/delete',
    method: 'post',
    data: {
      ids: ids
    }
  })
}

/**
 * 更新
 * @param data
 */
const update = function(data) {
  return request({
    url: '/pick/update',
    method: 'post',
    data: data
  })
}

/**
 * 添加
 * @param data
 */
const add = function(data) {
  return request({
    url: '/pick/add',
    method: 'post',
    data: data
  })
}

export const pickApi = {
  getList: getList,
  deleted: deleted,
  update: update,
  add: add
}
